package org.icnmasjid.member.model;

/**
 * @struts.form include-all="true" extends="BaseForm"
 * @hibernate.class
 *         table="school_payment"
 *     
 */

public class SchoolPayment extends BaseObject {
	private String email;
	private double amount;
	private String referenceId;
	private Boolean processed;
	private String paymentDate;
	private String comments;

	/**       @hibernate.id
     *             column="reference_id"
     *         
     */
	public String getReferenceId() {
		return referenceId;
	}

	public void setReferenceId(String referenceId) {
		this.referenceId = referenceId;
	}

	/**       
     *      *            @hibernate.property
     *             column="email"
     *         
     */
	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	/**       
     *      *            @hibernate.property
     *             column="amount"
     *         
     */	
	public double getAmount() {
		return amount;
	}

	public void setAmount(double amount) {
		this.amount = amount;
	}

	@Override
	public String toString() {
		return "SchoolPayment [email=" + email + ", amount=" + amount
				+ ", referenceId=" + referenceId + ", processed=" + processed
				+ "]";
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		SchoolPayment other = (SchoolPayment) obj;
		if (Double.doubleToLongBits(amount) != Double
				.doubleToLongBits(other.amount))
			return false;
		if (email == null) {
			if (other.email != null)
				return false;
		} else if (!email.equals(other.email))
			return false;
		if (processed == null) {
			if (other.processed != null)
				return false;
		} else if (!processed.equals(other.processed))
			return false;
		if (referenceId == null) {
			if (other.referenceId != null)
				return false;
		} else if (!referenceId.equals(other.referenceId))
			return false;
		return true;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		long temp;
		temp = Double.doubleToLongBits(amount);
		result = prime * result + (int) (temp ^ (temp >>> 32));
		result = prime * result + ((email == null) ? 0 : email.hashCode());
		result = prime * result
				+ ((processed == null) ? 0 : processed.hashCode());
		result = prime * result
				+ ((referenceId == null) ? 0 : referenceId.hashCode());
		return result;
	}
	
	/**
     *	@hibernate.property
     *             column="processed"
     *
     */	
	public Boolean getProcessed() {
		return processed;
	}

	public void setProcessed(Boolean processed) {
		this.processed = processed;
	}

	/**
     *	@hibernate.property
     *             column="date"
     *
     */
	public String getPaymentDate() {
		return paymentDate;
	}

	public void setPaymentDate(String paymentDate) {
		this.paymentDate = paymentDate;
	}

	/**
     *	@hibernate.property
     *             column="comments"
     *
     */	
	public String getComments() {
		return comments;
	}

	public void setComments(String comments) {
		this.comments = comments;
	}


}
